home *** CD-ROM | disk | FTP | other *** search
- From: envbvs@epb2.lbl.gov (Brian V. Smith)
- Newsgroups: comp.sources.x
- Subject: v06i050: xfig 2.0 (part 1/7), Patch5
- Message-ID: <133691@sun.Eng.Sun.COM>
- Date: 30 Mar 90 04:31:50 GMT
- Approved: argv@sun.com
-
- Submitted-by: envbvs@epb2.lbl.gov (Brian V. Smith)
- Posting-number: Volume 6, Issue 50
- Archive-name: xfig2/patch5a
- Patch-To: xfig2: Volume 6, Issue 9-24,34-36
-
- Here is part 1/7 of patch 5 for xfig 2.0.
-
- Changes from patchlevel 4:
-
- o Line widths of zero now allowed for drawing borderless objects
- o Resources now parsed in more portable way
- o Variable "compound" changed to "cmpnd" in drag.c and search.c because
- SunOs 4.1 has function called compound()
- o Unknown "-" options no longer parsed as file name
- o Filled areas now drawn opaquely instead of transparently
- o Ruler arrows now drawn correctly
- o Area fill for rounded corner boxes displays properly
- o Lower panel buttons and rulers slightly smaller to allow 9.5 inch tall
- canvas in portrait mode on screens that are "only" 864 pixels tall
- o Imakefile now uses XawClientDepLibs instead of $(DEPXAWLIB) $(DEPXMUlIB) ...
- o -1 for area fill (no fill) in TransFig files handled properly
- o u_int defined as uint for SYSV systems
- o 'figure_modified' flag cleared when editing new file
- o If "save in" is done and there is no current file name, then the
- current file name is set to the one specified in the save
- o -track default is now True as man entry states
- o side panel resource renamed to side_panel
- o fixed bug in f2ps where filled arcs weren't filled
- o line width and font support for f2p (pic)
- Thanks to Dave Davey for these additions
- _____________________________________
- Brian V. Smith (bvsmith@lbl.gov)
- Lawrence Berkeley Laboratory
- I don't speak for LBL, these non-opinions are all mine.
-
- ----------------------- cut --------------------------
- #! /bin/sh
- # This is a shell archive. Remove anything before this line, then unpack
- # it by saving it into a file and typing "sh file". To overwrite existing
- # files, type "sh file -c". You can also feed this as standard input via
- # unshar, or by typing "sh <file", e.g.. If this archive is complete, you
- # will see the following message at the end:
- # "End of archive 1 (of 7)."
- # Contents: addpt.c.diff arcbox.c.diff autoarrow.c.diff bitmap.c.diff
- # box.c.diff canvas.c.diff changethick.c.diff char.c.diff
- # const.h.diff corner.c.diff curve.c.diff deletept.c.diff fig.h.diff
- # file.c.diff font.c.diff global.c.diff glue.c.diff graphics.c.diff
- # grid.c.diff move.c.diff msgsw.c.diff patchlevel.h.diff
- # popup.c.diff read1_3.c.diff redisplay.c.diff remove.c.diff
- # resources.h.diff troff_fonts.c.diff troff_fonts.h.diff
- # troff_ft_codes.diff
- # Wrapped by envbvs@epb2.lbl.gov on Wed Mar 28 09:04:25 1990
- PATH=/bin:/usr/bin:/usr/ucb ; export PATH
- if test -f 'addpt.c.diff' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'addpt.c.diff'\"
- else
- echo shar: Extracting \"'addpt.c.diff'\" \(2035 characters\)
- sed "s/^X//" >'addpt.c.diff' <<'END_OF_FILE'
- X*** addpt.c.p5 Tue Jan 16 17:21:01 1990
- X--- addpt.c Sat Mar 17 13:32:13 1990
- X***************
- X*** 151,157 ****
- X return(-1);
- X }
- X }
- X- pw_batch_on(canvas_pixwin);
- X if (pointmarker_shown) toggle_splinepointmarker(spline);
- X draw_spline(spline, ERASE); /* erase old spline */
- X if (left_point == NULL) {
- X--- 151,156 ----
- X***************
- X*** 171,177 ****
- X
- X draw_spline(spline, PAINT); /* draw the modified spline */
- X if (pointmarker_shown) toggle_splinepointmarker(spline);
- X- pw_batch_off(canvas_pixwin);
- X reset_cursor();
- X set_modifiedflag();
- X return(1);
- X--- 170,175 ----
- X***************
- X*** 191,199 ****
- X right_point = right_point->next;
- X }
- X if (left_point != NULL && right_point != NULL)
- X! draw_line_segment(cur_line->style, cur_line->style_val,
- X! left_point->x, left_point->y,
- X! right_point->x, right_point->y, INV_PAINT, 1);
- X draw_addedlink(INV_PAINT);
- X if (latexline_mode || latexarrow_mode) {
- X canvas_locmove_proc = latex_elasticline;
- X--- 189,197 ----
- X right_point = right_point->next;
- X }
- X if (left_point != NULL && right_point != NULL)
- X! pw_vector(canvas_pixwin, left_point->x, left_point->y,
- X! right_point->x, right_point->y, INV_PAINT,
- X! cur_line->thickness, cur_line->style, cur_line->style_val);
- X draw_addedlink(INV_PAINT);
- X if (latexline_mode || latexarrow_mode) {
- X canvas_locmove_proc = latex_elasticline;
- X***************
- X*** 314,324 ****
- X {
- X if (left_point != NULL) {
- X pw_vector(canvas_pixwin, left_point->x, left_point->y,
- X! cur_x, cur_y, op, 1);
- X }
- X if (right_point != NULL) {
- X pw_vector(canvas_pixwin, right_point->x,
- X! right_point->y, cur_x, cur_y, op, 1);
- X }
- X }
- X
- X--- 312,322 ----
- X {
- X if (left_point != NULL) {
- X pw_vector(canvas_pixwin, left_point->x, left_point->y,
- X! cur_x, cur_y, op, 1, SOLID_LINE, 0.0);
- X }
- X if (right_point != NULL) {
- X pw_vector(canvas_pixwin, right_point->x,
- X! right_point->y, cur_x, cur_y, op, 1, SOLID_LINE, 0.0);
- X }
- X }
- X
- END_OF_FILE
- if test 2035 -ne `wc -c <'addpt.c.diff'`; then
- echo shar: \"'addpt.c.diff'\" unpacked with wrong size!
- fi
- # end of 'addpt.c.diff'
- fi
- if test -f 'arcbox.c.diff' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'arcbox.c.diff'\"
- else
- echo shar: Extracting \"'arcbox.c.diff'\" \(2104 characters\)
- sed "s/^X//" >'arcbox.c.diff' <<'END_OF_FILE'
- X*** arcbox.c.p5 Tue Jan 16 17:22:15 1990
- X--- arcbox.c Mon Mar 26 15:57:18 1990
- X***************
- X*** 14,20 ****
- X #include "object.h"
- X #include "paintop.h"
- X
- X! extern int cur_line_style, line_thickness;
- X extern float cur_styleval;
- X extern int cur_color;
- X extern int cur_areafill;
- X--- 14,20 ----
- X #include "object.h"
- X #include "paintop.h"
- X
- X! extern int line_style, line_thickness;
- X extern float cur_styleval;
- X extern int cur_color;
- X extern int cur_areafill;
- X***************
- X*** 56,62 ****
- X canvas_locmove_proc = elastic_box;
- X canvas_leftbut_proc = canvas_rightbut_proc = null_proc;
- X canvas_middlebut_proc = create_arc_boxobject;
- X! draw_rectbox(fix_x, fix_y, cur_x, cur_y, INV_PAINT, 1);
- X set_temp_cursor(&null_cursor);
- X set_action_on();
- X }
- X--- 56,62 ----
- X canvas_locmove_proc = elastic_box;
- X canvas_leftbut_proc = canvas_rightbut_proc = null_proc;
- X canvas_middlebut_proc = create_arc_boxobject;
- X! draw_rectbox(fix_x, fix_y, cur_x, cur_y, INV_PAINT);
- X set_temp_cursor(&null_cursor);
- X set_action_on();
- X }
- X***************
- X*** 68,74 ****
- X F_point *point;
- X int tmp;
- X
- X! draw_rectbox(fix_x, fix_y, cur_x, cur_y, INV_PAINT, 1);
- X
- X
- X if ((Point_malloc(point)) == NULL) {
- X--- 68,74 ----
- X F_point *point;
- X int tmp;
- X
- X! draw_rectbox(fix_x, fix_y, cur_x, cur_y, INV_PAINT);
- X
- X
- X if ((Point_malloc(point)) == NULL) {
- X***************
- X*** 76,93 ****
- X put_msg(Err_mem);
- X return;
- X }
- X- /* sort x and y so that the upper left is first */
- X- /*
- X- if (x > fix_x)
- X- {
- X- tmp = x; x = fix_x ; fix_x = tmp;
- X- }
- X-
- X- if (y > fix_y)
- X- {
- X- tmp = y; y = fix_y ; fix_y = tmp;
- X- }
- X- */
- X point->x = x;
- X point->y = y;
- X point->next = NULL;
- X--- 76,81 ----
- X***************
- X*** 94,100 ****
- X
- X Line_malloc(box);
- X box->type = T_ARC_BOX;
- X! box->style = cur_line_style;
- X box->thickness = line_thickness;
- X box->color = cur_color;
- X box->depth = NULL;
- X--- 82,88 ----
- X
- X Line_malloc(box);
- X box->type = T_ARC_BOX;
- X! box->style = line_style;
- X box->thickness = line_thickness;
- X box->color = cur_color;
- X box->depth = NULL;
- END_OF_FILE
- if test 2104 -ne `wc -c <'arcbox.c.diff'`; then
- echo shar: \"'arcbox.c.diff'\" unpacked with wrong size!
- fi
- # end of 'arcbox.c.diff'
- fi
- if test -f 'autoarrow.c.diff' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'autoarrow.c.diff'\"
- else
- echo shar: Extracting \"'autoarrow.c.diff'\" \(2510 characters\)
- sed "s/^X//" >'autoarrow.c.diff' <<'END_OF_FILE'
- X*** autoarrow.c.p5 Tue Jan 16 17:21:03 1990
- X--- autoarrow.c Fri Mar 16 14:19:11 1990
- X***************
- X*** 264,270 ****
- X selected_point->y, spline->back_arrow, ERASE);
- X pw_vector(canvas_pixwin, selected_point->x, selected_point->y,
- X round((p->x+selected_point->x)/2.0),
- X! round((p->y+selected_point->y)/2.0), PAINT, spline->thickness);
- X }
- X else {
- X F_control *a, *b;
- X--- 264,271 ----
- X selected_point->y, spline->back_arrow, ERASE);
- X pw_vector(canvas_pixwin, selected_point->x, selected_point->y,
- X round((p->x+selected_point->x)/2.0),
- X! round((p->y+selected_point->y)/2.0), PAINT,
- X! spline->thickness, spline->style, spline->style_val);
- X }
- X else {
- X F_control *a, *b;
- X***************
- X*** 276,282 ****
- X bezier_spline(
- X (float)selected_point->x, (float)selected_point->y,
- X a->rx, a->ry, b->lx, b->ly, (float)p->x, (float)p->y,
- X! PAINT,spline->thickness);
- X }
- X free((char*)spline->back_arrow);
- X spline->back_arrow = NULL;
- X--- 277,283 ----
- X bezier_spline(
- X (float)selected_point->x, (float)selected_point->y,
- X a->rx, a->ry, b->lx, b->ly, (float)p->x, (float)p->y,
- X! PAINT,spline->thickness, spline->style, spline->style_val);
- X }
- X free((char*)spline->back_arrow);
- X spline->back_arrow = NULL;
- X***************
- X*** 291,298 ****
- X spline->for_arrow, ERASE);
- X pw_vector(canvas_pixwin, selected_point->x, selected_point->y,
- X round((selected_point->x+left_point->x)/2.0),
- X! round((selected_point->y+left_point->y)/2.0),
- X! PAINT, spline->thickness);
- X }
- X else {
- X F_control *a, *b;
- X--- 292,299 ----
- X spline->for_arrow, ERASE);
- X pw_vector(canvas_pixwin, selected_point->x, selected_point->y,
- X round((selected_point->x+left_point->x)/2.0),
- X! round((selected_point->y+left_point->y)/2.0),
- X! PAINT, spline->thickness, spline->style, spline->style_val);
- X }
- X else {
- X F_control *a, *b;
- X***************
- X*** 305,311 ****
- X (float)left_point->x, (float)left_point->y,
- X a->rx, a->ry, b->lx, b->ly,
- X (float)selected_point->x, (float)selected_point->y,
- X! PAINT,spline->thickness);
- X }
- X free((char*)spline->for_arrow);
- X spline->for_arrow = NULL;
- X--- 306,312 ----
- X (float)left_point->x, (float)left_point->y,
- X a->rx, a->ry, b->lx, b->ly,
- X (float)selected_point->x, (float)selected_point->y,
- X! PAINT,spline->thickness, spline->style, spline->style_val);
- X }
- X free((char*)spline->for_arrow);
- X spline->for_arrow = NULL;
- END_OF_FILE
- if test 2510 -ne `wc -c <'autoarrow.c.diff'`; then
- echo shar: \"'autoarrow.c.diff'\" unpacked with wrong size!
- fi
- # end of 'autoarrow.c.diff'
- fi
- if test -f 'bitmap.c.diff' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'bitmap.c.diff'\"
- else
- echo shar: Extracting \"'bitmap.c.diff'\" \(1118 characters\)
- sed "s/^X//" >'bitmap.c.diff' <<'END_OF_FILE'
- X*** bitmap.c.p5 Fri Feb 16 10:59:40 1990
- X--- bitmap.c Thu Mar 15 15:26:10 1990
- X***************
- X*** 15,23 ****
- X extern F_compound objects;
- X
- X extern int errno;
- X- extern int DEBUG;
- X extern int pointmarker_shown;
- X extern int compoundbox_shown;
- X
- X extern char *sys_errlist[];
- X extern int sys_nerr, errno;
- X--- 15,23 ----
- X extern F_compound objects;
- X
- X extern int errno;
- X extern int pointmarker_shown;
- X extern int compoundbox_shown;
- X+ extern appresStruct appres;
- X
- X extern char *sys_errlist[];
- X extern int sys_nerr, errno;
- X***************
- X*** 78,85 ****
- X /* Assume that there is at least one object */
- X compound_bound(&objects, &xmin, &ymin, &xmax, &ymax);
- X
- X! if (DEBUG) {
- X! draw_rectbox(xmin, ymin, xmax, ymax, INV_PAINT, 1);
- X }
- X put_msg("Sorry, write_bitmap not implemented for X11 yet");
- X }
- X--- 78,85 ----
- X /* Assume that there is at least one object */
- X compound_bound(&objects, &xmin, &ymin, &xmax, &ymax);
- X
- X! if (appres.DEBUG) {
- X! draw_rectbox(xmin, ymin, xmax, ymax, INV_PAINT);
- X }
- X put_msg("Sorry, write_bitmap not implemented for X11 yet");
- X }
- END_OF_FILE
- if test 1118 -ne `wc -c <'bitmap.c.diff'`; then
- echo shar: \"'bitmap.c.diff'\" unpacked with wrong size!
- fi
- # end of 'bitmap.c.diff'
- fi
- if test -f 'box.c.diff' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'box.c.diff'\"
- else
- echo shar: Extracting \"'box.c.diff'\" \(2807 characters\)
- sed "s/^X//" >'box.c.diff' <<'END_OF_FILE'
- X*** box.c.p5 Tue Jan 16 17:21:03 1990
- X--- box.c Thu Mar 15 15:26:57 1990
- X***************
- X*** 14,20 ****
- X #include "object.h"
- X #include "paintop.h"
- X
- X! extern int cur_line_style, line_thickness;
- X extern float cur_styleval;
- X extern int cur_color;
- X extern int cur_areafill;
- X--- 14,20 ----
- X #include "object.h"
- X #include "paintop.h"
- X
- X! extern int line_style, line_thickness;
- X extern float cur_styleval;
- X extern int cur_color;
- X extern int cur_areafill;
- X***************
- X*** 55,81 ****
- X canvas_locmove_proc = elastic_box;
- X canvas_leftbut_proc = canvas_rightbut_proc = null_proc;
- X canvas_middlebut_proc = create_boxobject;
- X! draw_rectbox(fix_x, fix_y, cur_x, cur_y, INV_PAINT, 1);
- X set_temp_cursor(&null_cursor);
- X set_action_on();
- X }
- X
- X! draw_rectbox(x1, y1, x2, y2, op, thick)
- X! int x1, y1, x2, y2, op, thick;
- X {
- X! pw_vector(canvas_pixwin, x1, y1, x1, y2, op, thick);
- X! pw_vector(canvas_pixwin, x1, y2, x2, y2, op, thick);
- X! pw_vector(canvas_pixwin, x2, y2, x2, y1, op, thick);
- X! pw_vector(canvas_pixwin, x2, y1, x1, y1, op, thick);
- X }
- X
- X elastic_box(x, y)
- X int x, y;
- X {
- X! draw_rectbox(fix_x, fix_y, cur_x, cur_y, INV_PAINT, 1);
- X cur_x = x;
- X cur_y = y;
- X! draw_rectbox(fix_x, fix_y, cur_x, cur_y, INV_PAINT, 1);
- X }
- X
- X create_boxobject(x, y)
- X--- 55,81 ----
- X canvas_locmove_proc = elastic_box;
- X canvas_leftbut_proc = canvas_rightbut_proc = null_proc;
- X canvas_middlebut_proc = create_boxobject;
- X! draw_rectbox(fix_x, fix_y, cur_x, cur_y, INV_PAINT);
- X set_temp_cursor(&null_cursor);
- X set_action_on();
- X }
- X
- X! draw_rectbox(x1, y1, x2, y2, op)
- X! int x1, y1, x2, y2, op;
- X {
- X! pw_vector(canvas_pixwin, x1, y1, x1, y2, op, 1, SOLID_LINE);
- X! pw_vector(canvas_pixwin, x1, y2, x2, y2, op, 1, SOLID_LINE);
- X! pw_vector(canvas_pixwin, x2, y2, x2, y1, op, 1, SOLID_LINE);
- X! pw_vector(canvas_pixwin, x2, y1, x1, y1, op, 1, SOLID_LINE);
- X }
- X
- X elastic_box(x, y)
- X int x, y;
- X {
- X! draw_rectbox(fix_x, fix_y, cur_x, cur_y, INV_PAINT);
- X cur_x = x;
- X cur_y = y;
- X! draw_rectbox(fix_x, fix_y, cur_x, cur_y, INV_PAINT);
- X }
- X
- X create_boxobject(x, y)
- X***************
- X*** 84,90 ****
- X F_line *box;
- X F_point *point;
- X
- X! draw_rectbox(fix_x, fix_y, cur_x, cur_y, INV_PAINT, 1);
- X
- X
- X if ((Point_malloc(point)) == NULL) {
- X--- 84,90 ----
- X F_line *box;
- X F_point *point;
- X
- X! draw_rectbox(fix_x, fix_y, cur_x, cur_y, INV_PAINT);
- X
- X
- X if ((Point_malloc(point)) == NULL) {
- X***************
- X*** 98,104 ****
- X
- X Line_malloc(box);
- X box->type = T_BOX;
- X! box->style = cur_line_style;
- X box->thickness = line_thickness;
- X box->color = cur_color;
- X box->depth = NULL;
- X--- 98,104 ----
- X
- X Line_malloc(box);
- X box->type = T_BOX;
- X! box->style = line_style;
- X box->thickness = line_thickness;
- X box->color = cur_color;
- X box->depth = NULL;
- END_OF_FILE
- if test 2807 -ne `wc -c <'box.c.diff'`; then
- echo shar: \"'box.c.diff'\" unpacked with wrong size!
- fi
- # end of 'box.c.diff'
- fi
- if test -f 'canvas.c.diff' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'canvas.c.diff'\"
- else
- echo shar: Extracting \"'canvas.c.diff'\" \(2045 characters\)
- sed "s/^X//" >'canvas.c.diff' <<'END_OF_FILE'
- X*** canvas.c.p5 Wed Mar 7 11:47:11 1990
- X--- canvas.c Tue Mar 20 17:28:54 1990
- X***************
- X*** 39,55 ****
- X
- X static Arg canvas_args[] =
- X {
- X! /* 0 */ { XtNx, (XtArgVal)0 },
- X! /* 1 */ { XtNy, (XtArgVal)0 },
- X! /* 2 */ { XtNlabel, (XtArgVal)"" },
- X! /* 3 */ { XtNwidth, (XtArgVal)0 },
- X! /* 4 */ { XtNheight, (XtArgVal)0 },
- X! /* 5 */ { XtNfromHoriz, (XtArgVal)NULL },
- X! /* 6 */ { XtNhorizDistance, (XtArgVal)0 },
- X! /* 7 */ { XtNfromVert, (XtArgVal)NULL },
- X! /* 8 */ { XtNvertDistance, (XtArgVal)0 },
- X! /* 9 */ { XtNtop, (XtArgVal)XtChainTop },
- X! /*10 */ { XtNleft, (XtArgVal)XtChainLeft },
- X };
- X
- X static void
- X--- 39,53 ----
- X
- X static Arg canvas_args[] =
- X {
- X! /* 0 */ { XtNlabel, (XtArgVal)"" },
- X! /* 1 */ { XtNwidth, (XtArgVal) 0 },
- X! /* 2 */ { XtNheight, (XtArgVal) 0 },
- X! /* 3 */ { XtNfromHoriz, (XtArgVal)NULL },
- X! /* 4 */ { XtNhorizDistance, (XtArgVal) 0 },
- X! /* 5 */ { XtNfromVert, (XtArgVal)NULL },
- X! /* 6 */ { XtNvertDistance, (XtArgVal) 0 },
- X! /* 7 */ { XtNtop, (XtArgVal)XtChainTop },
- X! /* 8 */ { XtNleft, (XtArgVal)XtChainLeft },
- X };
- X
- X static void
- X***************
- X*** 108,117 ****
- X {
- X XColor fixcolors[2];
- X
- X! canvas_args[3].value = CANVAS_WIDTH;
- X! canvas_args[4].value = CANVAS_HEIGHT;
- X! canvas_args[5].value = (XtArgVal)panel_sw; /* to the right of the panel */
- X! canvas_args[7].value = (XtArgVal)topruler_sw; /* below the top ruler */
- X canvas_sw = XtCreateWidget("canvas", labelWidgetClass, tool,
- X canvas_args, XtNumber(canvas_args));
- X XtGetValues(canvas_sw, canvas_color_args, XtNumber(canvas_color_args));
- X--- 106,115 ----
- X {
- X XColor fixcolors[2];
- X
- X! canvas_args[1].value = CANVAS_WIDTH;
- X! canvas_args[2].value = CANVAS_HEIGHT;
- X! canvas_args[3].value = (XtArgVal)panel_sw; /* to the right of the panel */
- X! canvas_args[5].value = (XtArgVal)topruler_sw; /* below the top ruler */
- X canvas_sw = XtCreateWidget("canvas", labelWidgetClass, tool,
- X canvas_args, XtNumber(canvas_args));
- X XtGetValues(canvas_sw, canvas_color_args, XtNumber(canvas_color_args));
- END_OF_FILE
- if test 2045 -ne `wc -c <'canvas.c.diff'`; then
- echo shar: \"'canvas.c.diff'\" unpacked with wrong size!
- fi
- # end of 'canvas.c.diff'
- fi
- if test -f 'changethick.c.diff' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'changethick.c.diff'\"
- else
- echo shar: Extracting \"'changethick.c.diff'\" \(1453 characters\)
- sed "s/^X//" >'changethick.c.diff' <<'END_OF_FILE'
- X*** changethick.c.p5 Tue Jan 16 17:22:15 1990
- X--- changethick.c Sat Mar 17 13:32:46 1990
- X***************
- X*** 71,81 ****
- X }
- X else if ((e = ellipse_search(x, y, TOLERANCE, &px, &py)) != NULL) {
- X win_setmouseposition(canvas_swfd, px, py);
- X- pw_batch_on(canvas_pixwin);
- X draw_ellipse(e, background_color);
- X e->thickness = line_thickness;
- X draw_ellipse(e, foreground_color);
- X- pw_batch_off(canvas_pixwin);
- X clean_up();
- X set_action_object(F_CHANGE_THICK, O_ELLIPSE);
- X set_latestellipse(e);
- X--- 71,79 ----
- X***************
- X*** 83,93 ****
- X }
- X else if ((a = arc_search(x, y, TOLERANCE, &px, &py)) != NULL) {
- X win_setmouseposition(canvas_swfd, px, py);
- X- pw_batch_on(canvas_pixwin);
- X draw_arc(a, background_color);
- X a->thickness = line_thickness;
- X draw_arc(a, foreground_color);
- X- pw_batch_off(canvas_pixwin);
- X clean_up();
- X set_action_object(F_CHANGE_THICK, O_ARC);
- X set_latestarc(a);
- X--- 81,89 ----
- X***************
- X*** 95,105 ****
- X }
- X else if ((s = spline_search(x, y, TOLERANCE, &px, &py)) != NULL) {
- X win_setmouseposition(canvas_swfd, px, py);
- X- pw_batch_on(canvas_pixwin);
- X draw_spline(s, ERASE);
- X s->thickness = line_thickness;
- X draw_spline(s, PAINT);
- X- pw_batch_off(canvas_pixwin);
- X clean_up();
- X set_action_object(F_CHANGE_THICK, O_SPLINE);
- X set_latestspline(s);
- X--- 91,99 ----
- END_OF_FILE
- if test 1453 -ne `wc -c <'changethick.c.diff'`; then
- echo shar: \"'changethick.c.diff'\" unpacked with wrong size!
- fi
- # end of 'changethick.c.diff'
- fi
- if test -f 'char.c.diff' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'char.c.diff'\"
- else
- echo shar: Extracting \"'char.c.diff'\" \(412 characters\)
- sed "s/^X//" >'char.c.diff' <<'END_OF_FILE'
- X*** char.c.p5 Wed Feb 28 12:11:43 1990
- X--- char.c Fri Mar 16 14:20:34 1990
- X***************
- X*** 36,42 ****
- X draw_cursor(x, y)
- X int x, y;
- X {
- X! pw_vector(pw, x, y, x, y-char_ht, INV_PAINT, 1);
- X }
- X
- X initialize_char_handler(p, cr, bx, by)
- X--- 36,42 ----
- X draw_cursor(x, y)
- X int x, y;
- X {
- X! pw_vector(pw, x, y, x, y-char_ht, INV_PAINT, 1, SOLID_LINE, 0.0);
- X }
- X
- X initialize_char_handler(p, cr, bx, by)
- END_OF_FILE
- if test 412 -ne `wc -c <'char.c.diff'`; then
- echo shar: \"'char.c.diff'\" unpacked with wrong size!
- fi
- # end of 'char.c.diff'
- fi
- if test -f 'const.h.diff' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'const.h.diff'\"
- else
- echo shar: Extracting \"'const.h.diff'\" \(1204 characters\)
- sed "s/^X//" >'const.h.diff' <<'END_OF_FILE'
- X*** const.h.p5 Thu Mar 8 16:33:41 1990
- X--- const.h Tue Mar 20 13:33:55 1990
- X***************
- X*** 10,16 ****
- X #define PIX_PER_CM 30 /* ((int)(PIX_PER_INCH / 2.54 + (5.0/2))) */
- X
- X /* Portrait dimensions */
- X! #define DEF_CANVAS_HEIGHT_P 9.25*PIX_PER_INCH
- X #define DEF_CANVAS_WIDTH_P 8*PIX_PER_INCH
- X
- X /* Landscape dimensions */
- X--- 10,16 ----
- X #define PIX_PER_CM 30 /* ((int)(PIX_PER_INCH / 2.54 + (5.0/2))) */
- X
- X /* Portrait dimensions */
- X! #define DEF_CANVAS_HEIGHT_P 9.5*PIX_PER_INCH
- X #define DEF_CANVAS_WIDTH_P 8*PIX_PER_INCH
- X
- X /* Landscape dimensions */
- X***************
- X*** 17,25 ****
- X #define DEF_CANVAS_HEIGHT_L 8*PIX_PER_INCH
- X #define DEF_CANVAS_WIDTH_L 10*PIX_PER_INCH
- X
- X! #define RULER_WIDTH 24
- X
- X! #define MSG_HEIGHT 25
- X
- X #define ICON_COLUMN_PORT 3 /* number of switches wide in panel */
- X #define ICON_COLUMN_LAND 3 /* same for landscape mode */
- X--- 17,25 ----
- X #define DEF_CANVAS_HEIGHT_L 8*PIX_PER_INCH
- X #define DEF_CANVAS_WIDTH_L 10*PIX_PER_INCH
- X
- X! #define RULER_WIDTH 20
- X
- X! #define MSG_HEIGHT 21
- X
- X #define ICON_COLUMN_PORT 3 /* number of switches wide in panel */
- X #define ICON_COLUMN_LAND 3 /* same for landscape mode */
- END_OF_FILE
- if test 1204 -ne `wc -c <'const.h.diff'`; then
- echo shar: \"'const.h.diff'\" unpacked with wrong size!
- fi
- # end of 'const.h.diff'
- fi
- if test -f 'corner.c.diff' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'corner.c.diff'\"
- else
- echo shar: Extracting \"'corner.c.diff'\" \(1823 characters\)
- sed "s/^X//" >'corner.c.diff' <<'END_OF_FILE'
- X*** corner.c.p5 Tue Jan 16 17:21:33 1990
- X--- corner.c Thu Mar 15 15:27:08 1990
- X***************
- X*** 14,20 ****
- X #include "object.h"
- X #include "paintop.h"
- X
- X! extern int cur_line_style, line_thickness;
- X extern float cur_styleval;
- X extern int cur_color;
- X extern int fix_x, fix_y, cur_x, cur_y;
- X--- 14,20 ----
- X #include "object.h"
- X #include "paintop.h"
- X
- X! extern int line_style, line_thickness;
- X extern float cur_styleval;
- X extern int cur_color;
- X extern int fix_x, fix_y, cur_x, cur_y;
- X***************
- X*** 54,60 ****
- X canvas_locmove_proc = elastic_box;
- X canvas_leftbut_proc = canvas_rightbut_proc = null_proc;
- X canvas_middlebut_proc = create_arc_cornerobject;
- X! draw_rectbox(fix_x, fix_y, cur_x, cur_y, INV_PAINT, 1);
- X set_temp_cursor(&null_cursor);
- X set_action_on();
- X }
- X--- 54,60 ----
- X canvas_locmove_proc = elastic_box;
- X canvas_leftbut_proc = canvas_rightbut_proc = null_proc;
- X canvas_middlebut_proc = create_arc_cornerobject;
- X! draw_rectbox(fix_x, fix_y, cur_x, cur_y, INV_PAINT);
- X set_temp_cursor(&null_cursor);
- X set_action_on();
- X }
- X***************
- X*** 66,72 ****
- X F_point *point;
- X int tmp;
- X
- X! draw_rectbox(fix_x, fix_y, cur_x, cur_y, INV_PAINT, 1);
- X
- X
- X if ((Point_malloc(point)) == NULL) {
- X--- 66,72 ----
- X F_point *point;
- X int tmp;
- X
- X! draw_rectbox(fix_x, fix_y, cur_x, cur_y, INV_PAINT);
- X
- X
- X if ((Point_malloc(point)) == NULL) {
- X***************
- X*** 94,100 ****
- X
- X Line_malloc(corner);
- X corner->type = T_ARC_CORNER;
- X! corner->style = cur_line_style;
- X corner->thickness = line_thickness;
- X corner->color = cur_color;
- X corner->depth = NULL;
- X--- 94,100 ----
- X
- X Line_malloc(corner);
- X corner->type = T_ARC_CORNER;
- X! corner->style = line_style;
- X corner->thickness = line_thickness;
- X corner->color = cur_color;
- X corner->depth = NULL;
- END_OF_FILE
- if test 1823 -ne `wc -c <'corner.c.diff'`; then
- echo shar: \"'corner.c.diff'\" unpacked with wrong size!
- fi
- # end of 'corner.c.diff'
- fi
- if test -f 'curve.c.diff' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'curve.c.diff'\"
- else
- echo shar: Extracting \"'curve.c.diff'\" \(1107 characters\)
- sed "s/^X//" >'curve.c.diff' <<'END_OF_FILE'
- X*** curve.c.p5 Fri Mar 9 10:56:32 1990
- X--- curve.c Fri Mar 16 14:24:49 1990
- X***************
- X*** 33,42 ****
- X static XPoint *points=NULL;
- X
- X curve(window, xstart, ystart, xend, yend, direction,
- X! a, b, xoff, yoff, val, thick, area_fill)
- X Window window;
- X int xstart, ystart, xend, yend, a, b, xoff, yoff;
- X! int direction, val, thick, area_fill;
- X {
- X int dfx, dfy, dfxx, dfyy;
- X int falpha, fx, fy, fxy, absfx, absfy, absfxy;
- X--- 33,43 ----
- X static XPoint *points=NULL;
- X
- X curve(window, xstart, ystart, xend, yend, direction,
- X! a, b, xoff, yoff, val, thick, style, style_val, area_fill)
- X Window window;
- X int xstart, ystart, xend, yend, a, b, xoff, yoff;
- X! int direction, val, thick, style, area_fill;
- X! float style_val;
- X {
- X int dfx, dfy, dfxx, dfyy;
- X int falpha, fx, fy, fxy, absfx, absfy, absfxy;
- X***************
- X*** 115,119 ****
- X npoints++;
- X }
- X pw_lines(window, points, npoints, val? PAINT: ERASE,
- X! thick, area_fill);
- X }
- X--- 116,120 ----
- X npoints++;
- X }
- X pw_lines(window, points, npoints, val? PAINT: ERASE,
- X! thick, style, style_val, area_fill);
- X }
- END_OF_FILE
- if test 1107 -ne `wc -c <'curve.c.diff'`; then
- echo shar: \"'curve.c.diff'\" unpacked with wrong size!
- fi
- # end of 'curve.c.diff'
- fi
- if test -f 'deletept.c.diff' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'deletept.c.diff'\"
- else
- echo shar: Extracting \"'deletept.c.diff'\" \(932 characters\)
- sed "s/^X//" >'deletept.c.diff' <<'END_OF_FILE'
- X*** deletept.c.p5 Tue Jan 16 17:21:04 1990
- X--- deletept.c Sat Mar 17 13:33:12 1990
- X***************
- X*** 122,128 ****
- X
- X set_temp_cursor(&wait_cursor);
- X if (closed_spline(spline)) {
- X- pw_batch_on(canvas_pixwin);
- X if (pointmarker_shown) toggle_splinepointmarker(spline);
- X draw_spline(spline, ERASE); /*erase the spline */
- X if (left_point == NULL) {
- X--- 122,127 ----
- X***************
- X*** 149,155 ****
- X left_point->next = right_point;
- X }
- X else { /* open spline */
- X- pw_batch_on(canvas_pixwin);
- X if (pointmarker_shown) toggle_splinepointmarker(spline);
- X draw_spline(spline, ERASE); /*erase the spline */
- X if (left_point == NULL)
- X--- 148,153 ----
- X***************
- X*** 168,174 ****
- X }
- X draw_spline(spline, PAINT);
- X if (pointmarker_shown) toggle_splinepointmarker(spline);
- X- pw_batch_off(canvas_pixwin);
- X set_modifiedflag();
- X reset_cursor();
- X }
- X--- 166,171 ----
- END_OF_FILE
- if test 932 -ne `wc -c <'deletept.c.diff'`; then
- echo shar: \"'deletept.c.diff'\" unpacked with wrong size!
- fi
- # end of 'deletept.c.diff'
- fi
- if test -f 'fig.h.diff' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'fig.h.diff'\"
- else
- echo shar: Extracting \"'fig.h.diff'\" \(307 characters\)
- sed "s/^X//" >'fig.h.diff' <<'END_OF_FILE'
- X*** fig.h.p5 Fri Mar 2 16:10:16 1990
- X--- fig.h Wed Mar 21 13:46:50 1990
- X***************
- X*** 19,24 ****
- X--- 19,28 ----
- X #include <errno.h>
- X #include <math.h>
- X
- X+ #ifdef SYSV
- X+ #define u_int uint
- X+ #endif
- X+
- X #ifndef M_PI
- X #define M_PI 3.14159265358979323846
- X #define M_PI_2 1.57079632679489661923
- END_OF_FILE
- if test 307 -ne `wc -c <'fig.h.diff'`; then
- echo shar: \"'fig.h.diff'\" unpacked with wrong size!
- fi
- # end of 'fig.h.diff'
- fi
- if test -f 'file.c.diff' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'file.c.diff'\"
- else
- echo shar: Extracting \"'file.c.diff'\" \(875 characters\)
- sed "s/^X//" >'file.c.diff' <<'END_OF_FILE'
- X*** file.c.p5 Tue Jan 16 17:21:06 1990
- X--- file.c Thu Mar 22 15:22:20 1990
- X***************
- X*** 60,65 ****
- X--- 60,66 ----
- X else if (s > 0)
- X read_fail_message(file, s);
- X reset_cursor();
- X+ figure_modified = 0;
- X }
- X
- X read_file(file)
- X***************
- X*** 88,96 ****
- X saved_objects = c;
- X tail(&objects, &object_tails);
- X append_objects(&objects, &saved_objects, &object_tails);
- X- pw_batch_on(canvas_pixwin);
- X redisplay_canvas();
- X- pw_batch_off(canvas_pixwin);
- X put_msg("File \"%s\" %d objects", file, num_object);
- X set_action_object(F_CREATE, O_ALL_OBJECT);
- X }
- X--- 89,95 ----
- X***************
- X*** 113,118 ****
- X--- 112,119 ----
- X save_file(file)
- X char *file;
- X {
- X+ if (*current_file=='\0') /* no current file, make this the current one */
- X+ strcpy(current_file, file);
- X return(write_file(file, PROMPT));
- X }
- X
- END_OF_FILE
- if test 875 -ne `wc -c <'file.c.diff'`; then
- echo shar: \"'file.c.diff'\" unpacked with wrong size!
- fi
- # end of 'file.c.diff'
- fi
- if test -f 'font.c.diff' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'font.c.diff'\"
- else
- echo shar: Extracting \"'font.c.diff'\" \(1958 characters\)
- sed "s/^X//" >'font.c.diff' <<'END_OF_FILE'
- X*** font.c.p5 Tue Feb 20 09:25:26 1990
- X--- font.c Thu Mar 15 12:10:01 1990
- X***************
- X*** 17,22 ****
- X--- 17,23 ----
- X PIX_FONT button_font;
- X
- X extern struct _fstruct fontnames[NUMFONTS];
- X+ extern appresStruct appres;
- X
- X XFontStruct *XLoadQueryFont();
- X #define MAXNAMES 30
- X***************
- X*** 26,34 ****
- X int s;
- X } flist[MAXNAMES];
- X
- X- char *boldFont = NULL;
- X- char *normalFont = NULL;
- X-
- X init_font()
- X {
- X struct xfont *newfont, *nf;
- X--- 27,32 ----
- X***************
- X*** 35,57 ****
- X int f,count,i,p,ss;
- X char **fontlist,**fname,*np;
- X
- X! if( boldFont == NULL || *boldFont == NULL)
- X! boldFont = BOLD_FONT;
- X! if( normalFont == NULL || *normalFont == NULL)
- X! normalFont = NORMAL_FONT;
- X
- X! roman_font = XLoadQueryFont(tool_d, normalFont);
- X! if ((bold_font = XLoadQueryFont(tool_d, boldFont)) ==0)
- X {
- X! fprintf(stderr,"Can't load font: %s, using %s\n",boldFont,normalFont);
- X! bold_font = XLoadQueryFont(tool_d, normalFont);
- X }
- X button_font = XLoadQueryFont(tool_d, NORMAL_FONT);
- X
- X for (i=0; i<0x10; i++)
- X {
- X! cur_gcfont[i] = -1;
- X! cur_gcfontsize[i] = 0;
- X }
- X
- X /* Now initialize the font structure for the X fonts corresponding
- X--- 33,56 ----
- X int f,count,i,p,ss;
- X char **fontlist,**fname,*np;
- X
- X! if( appres.boldFont == NULL || *appres.boldFont == NULL)
- X! appres.boldFont = BOLD_FONT;
- X! if( appres.normalFont == NULL || *appres.normalFont == NULL)
- X! appres.normalFont = NORMAL_FONT;
- X
- X! roman_font = XLoadQueryFont(tool_d, appres.normalFont);
- X! if ((bold_font = XLoadQueryFont(tool_d, appres.boldFont)) ==0)
- X {
- X! fprintf(stderr,"Can't load font: %s, using %s\n",
- X! appres.boldFont,appres.normalFont);
- X! bold_font = XLoadQueryFont(tool_d, appres.normalFont);
- X }
- X button_font = XLoadQueryFont(tool_d, NORMAL_FONT);
- X
- X for (i=0; i<0x10; i++)
- X {
- X! gc_font[i] = -1;
- X! gc_fontsize[i] = 0;
- X }
- X
- X /* Now initialize the font structure for the X fonts corresponding
- END_OF_FILE
- if test 1958 -ne `wc -c <'font.c.diff'`; then
- echo shar: \"'font.c.diff'\" unpacked with wrong size!
- fi
- # end of 'font.c.diff'
- fi
- if test -f 'global.c.diff' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'global.c.diff'\"
- else
- echo shar: Extracting \"'global.c.diff'\" \(2926 characters\)
- sed "s/^X//" >'global.c.diff' <<'END_OF_FILE'
- X*** global.c.p5 Tue Mar 13 10:18:27 1990
- X--- global.c Fri Mar 16 17:01:18 1990
- X***************
- X*** 43,49 ****
- X int SIDERULER_START;
- X int TOPRULER_LEFT, TOPRULER_TOP;
- X int TOPRULER_WIDTH, TOPRULER_HEIGHT;
- X- int INCHES;
- X int borderwid, windowspacing, toolstripeht;
- X
- X int num_point;
- X--- 43,48 ----
- X***************
- X*** 91,96 ****
- X--- 90,96 ----
- X int latexarrow_mode = 0;
- X int magnet_mode = 0;
- X int line_thickness = 1;
- X+ int line_style = SOLID_LINE;
- X int cur_radius = 7;
- X int pen_size = 0;
- X int pen_type = 0;
- X***************
- X*** 97,103 ****
- X int flip_axis = -1;
- X int rotate_angle = 0;
- X int fill_mode = 0;
- X- int landscape = 0;
- X int print_landscape = 0; /* def. orientation for printer */
- X int size_button; /* font size button value */
- X int font_button = 0; /* font button value */
- X--- 97,102 ----
- X***************
- X*** 105,113 ****
- X int cur_font; /* font of current text object */
- X int cur_fontsize; /* size of current text object font */
- X int cur_areafill = 1;
- X! int cur_line_style = -1;
- X! float cur_dashlength = .05*PIX_PER_INCH;
- X! float cur_dotgap = .04*PIX_PER_INCH;
- X float cur_styleval = 0.0;
- X float cur_angle = 0.0;
- X int cur_color = BLACK;
- X--- 104,111 ----
- X int cur_font; /* font of current text object */
- X int cur_fontsize; /* size of current text object font */
- X int cur_areafill = 1;
- X! float cur_dashlength = 4;
- X! float cur_dotgap = 3;
- X float cur_styleval = 0.0;
- X float cur_angle = 0.0;
- X int cur_color = BLACK;
- X***************
- X*** 114,122 ****
- X int cur_textstyle = PLAIN;
- X int cur_texttype = T_LEFT_JUSTIFIED;
- X /* line thicknesses for each gc */
- X! int cur_thickness[0x10] = {1,1,1,1,1,1,1,1,
- X 1,1,1,1,1,1,1,1};
- X!
- X short dot_image[16] = {
- X 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF,
- X 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF,
- X--- 112,121 ----
- X int cur_textstyle = PLAIN;
- X int cur_texttype = T_LEFT_JUSTIFIED;
- X /* line thicknesses for each gc */
- X! int gc_thickness[0x10] = {1,1,1,1,1,1,1,1,
- X 1,1,1,1,1,1,1,1};
- X! int gc_line_style[0x10] = {-1,-1,-1,-1,-1,-1,-1,-1,
- X! -1,-1,-1,-1,-1,-1,-1,-1};
- X short dot_image[16] = {
- X 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF,
- X 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF,
- X***************
- X*** 125,137 ****
- X };
- X mpr_static(dot, 16, 16, 1, dot_image);
- X
- X! /************************* Flags *******************************/
- X
- X int cur_command = -1;
- X! int DEBUG = 0;
- X! int RHS_PANEL = 0;
- X! int INVERSE = 0;
- X! int TRACKING = 1;
- X
- X /************************ Status ****************************/
- X
- X--- 124,136 ----
- X };
- X mpr_static(dot, 16, 16, 1, dot_image);
- X
- X! /************************* Flags/Resources *******************************/
- X
- X int cur_command = -1;
- X!
- X! /* Resources */
- X!
- X! appresStruct appres;
- X
- X /************************ Status ****************************/
- X
- END_OF_FILE
- if test 2926 -ne `wc -c <'global.c.diff'`; then
- echo shar: \"'global.c.diff'\" unpacked with wrong size!
- fi
- # end of 'global.c.diff'
- fi
- if test -f 'glue.c.diff' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'glue.c.diff'\"
- else
- echo shar: Extracting \"'glue.c.diff'\" \(1702 characters\)
- sed "s/^X//" >'glue.c.diff' <<'END_OF_FILE'
- X*** glue.c.p5 Tue Jan 16 17:21:02 1990
- X--- glue.c Sat Mar 17 13:34:21 1990
- X***************
- X*** 67,73 ****
- X put_msg(Err_mem);
- X return;
- X }
- X! draw_rectbox(fix_x, fix_y, cur_x, cur_y, INV_PAINT, 1);
- X c->nwcorner.x = min(fix_x, x);
- X c->nwcorner.y = min(fix_y, y);
- X c->secorner.x = max(fix_x, x);
- X--- 67,73 ----
- X put_msg(Err_mem);
- X return;
- X }
- X! draw_rectbox(fix_x, fix_y, cur_x, cur_y, INV_PAINT);
- X c->nwcorner.x = min(fix_x, x);
- X c->nwcorner.y = min(fix_y, y);
- X c->secorner.x = max(fix_x, x);
- X***************
- X*** 124,134 ****
- X int op;
- X {
- X draw_rectbox( c->nwcorner.x-1, c->nwcorner.y-1,
- X! c->secorner.x+1, c->secorner.y+1, op, 1);
- X draw_rectbox( c->nwcorner.x, c->nwcorner.y,
- X! c->secorner.x, c->secorner.y, op, 1);
- X draw_rectbox( c->nwcorner.x+1, c->nwcorner.y+1,
- X! c->secorner.x-1, c->secorner.y-1, op, 1);
- X }
- X
- X get_ellipse(list, xmin, ymin, xmax, ymax)
- X--- 124,134 ----
- X int op;
- X {
- X draw_rectbox( c->nwcorner.x-1, c->nwcorner.y-1,
- X! c->secorner.x+1, c->secorner.y+1, op);
- X draw_rectbox( c->nwcorner.x, c->nwcorner.y,
- X! c->secorner.x, c->secorner.y, op);
- X draw_rectbox( c->nwcorner.x+1, c->nwcorner.y+1,
- X! c->secorner.x-1, c->secorner.y-1, op);
- X }
- X
- X get_ellipse(list, xmin, ymin, xmax, ymax)
- X***************
- X*** 382,388 ****
- X F_arc *a;
- X F_compound *c1;
- X
- X- pw_batch_on(canvas_pixwin);
- X for (l = c->lines; l != NULL; l = l->next) {
- X draw_line(l, lineop);
- X }
- X--- 382,387 ----
- X***************
- X*** 402,408 ****
- X draw_compoundbox(c1, INV_PAINT);
- X compop == ERASE ? erase_compound(c1) : draw_compound(c1);
- X }
- X- pw_batch_off(canvas_pixwin);
- X }
- X
- X F_compound *
- X--- 401,406 ----
- END_OF_FILE
- if test 1702 -ne `wc -c <'glue.c.diff'`; then
- echo shar: \"'glue.c.diff'\" unpacked with wrong size!
- fi
- # end of 'glue.c.diff'
- fi
- if test -f 'graphics.c.diff' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'graphics.c.diff'\"
- else
- echo shar: Extracting \"'graphics.c.diff'\" \(3193 characters\)
- sed "s/^X//" >'graphics.c.diff' <<'END_OF_FILE'
- X*** graphics.c.p5 Tue Jan 16 17:21:06 1990
- X--- graphics.c Fri Mar 16 14:20:03 1990
- X***************
- X*** 33,41 ****
- X #define THRESHOLD 5
- X
- X /* iterative version */
- X! quadratic_spline(a1, b1, a2, b2, a3, b3, a4, b4, op, thick)
- X float a1, b1, a2, b2, a3, b3, a4, b4;
- X! int op, thick;
- X {
- X float x1, y1, x2, y2, x3, y3, x4, y4;
- X float xmid, ymid;
- X--- 33,45 ----
- X #define THRESHOLD 5
- X
- X /* iterative version */
- X! /* because we draw the spline with small line segments, the style
- X! parameter doesn't work */
- X!
- X! quadratic_spline(a1, b1, a2, b2, a3, b3, a4, b4, op, thick, style, style_val)
- X float a1, b1, a2, b2, a3, b3, a4, b4;
- X! int op, thick, style;
- X! float style_val;
- X {
- X float x1, y1, x2, y2, x3, y3, x4, y4;
- X float xmid, ymid;
- X***************
- X*** 48,54 ****
- X ymid = half(y2, y3);
- X if (fabs(x1 - xmid) < THRESHOLD && fabs(y1 - ymid) < THRESHOLD) {
- X pw_vector(canvas_pixwin, round(x1), round(y1),
- X! round(xmid), round(ymid), op, thick);
- X }
- X else {
- X push(x1, y1, half(x1, x2), half(y1, y2),
- X--- 52,58 ----
- X ymid = half(y2, y3);
- X if (fabs(x1 - xmid) < THRESHOLD && fabs(y1 - ymid) < THRESHOLD) {
- X pw_vector(canvas_pixwin, round(x1), round(y1),
- X! round(xmid), round(ymid), op, thick, style, style_val);
- X }
- X else {
- X push(x1, y1, half(x1, x2), half(y1, y2),
- X***************
- X*** 57,63 ****
- X
- X if (fabs(xmid - x4) < THRESHOLD && fabs(ymid - y4) < THRESHOLD) {
- X pw_vector(canvas_pixwin, round(xmid), round(ymid),
- X! round(x4), round(y4), op, thick);
- X }
- X else {
- X push(xmid, ymid, half(xmid, x3), half(ymid, y3),
- X--- 61,67 ----
- X
- X if (fabs(xmid - x4) < THRESHOLD && fabs(ymid - y4) < THRESHOLD) {
- X pw_vector(canvas_pixwin, round(xmid), round(ymid),
- X! round(x4), round(y4), op, thick, style, style_val);
- X }
- X else {
- X push(xmid, ymid, half(xmid, x3), half(ymid, y3),
- X***************
- X*** 66,74 ****
- X }
- X }
- X
- X! bezier_spline(a0, b0, a1, b1, a2, b2, a3, b3, op, thick)
- X float a0, b0, a1, b1, a2, b2, a3, b3;
- X! int op, thick;
- X {
- X float x0, y0, x1, y1, x2, y2, x3, y3;
- X float sx1, sy1, sx2, sy2, tx, ty, tx1, ty1, tx2, ty2, xmid, ymid;
- X--- 70,82 ----
- X }
- X }
- X
- X! /* because we draw the spline with small line segments, the style
- X! parameter doesn't work */
- X!
- X! bezier_spline(a0, b0, a1, b1, a2, b2, a3, b3, op, thick, style, style_val)
- X float a0, b0, a1, b1, a2, b2, a3, b3;
- X! int op, thick, style;
- X! float style_val;
- X {
- X float x0, y0, x1, y1, x2, y2, x3, y3;
- X float sx1, sy1, sx2, sy2, tx, ty, tx1, ty1, tx2, ty2, xmid, ymid;
- X***************
- X*** 79,85 ****
- X while(pop(&x0, &y0, &x1, &y1, &x2, &y2, &x3, &y3)) {
- X if (fabs(x0 - x3) < THRESHOLD && fabs(y0 - y3) < THRESHOLD) {
- X pw_vector(canvas_pixwin, round(x0), round(y0),
- X! round(x3), round(y3), op, thick);
- X }
- X else {
- X tx = half(x1, x2); ty = half(y1, y2);
- X--- 87,93 ----
- X while(pop(&x0, &y0, &x1, &y1, &x2, &y2, &x3, &y3)) {
- X if (fabs(x0 - x3) < THRESHOLD && fabs(y0 - y3) < THRESHOLD) {
- X pw_vector(canvas_pixwin, round(x0), round(y0),
- X! round(x3), round(y3), op, thick, style, style_val);
- X }
- X else {
- X tx = half(x1, x2); ty = half(y1, y2);
- END_OF_FILE
- if test 3193 -ne `wc -c <'graphics.c.diff'`; then
- echo shar: \"'graphics.c.diff'\" unpacked with wrong size!
- fi
- # end of 'graphics.c.diff'
- fi
- if test -f 'grid.c.diff' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'grid.c.diff'\"
- else
- echo shar: Extracting \"'grid.c.diff'\" \(793 characters\)
- sed "s/^X//" >'grid.c.diff' <<'END_OF_FILE'
- X*** grid.c.p5 Tue Jan 16 17:21:02 1990
- X--- grid.c Tue Mar 13 14:44:47 1990
- X***************
- X*** 15,21 ****
- X
- X static int cur_grid = -1;
- X extern int CANVAS_WIDTH, CANVAS_HEIGHT;
- X! extern int INCHES;
- X
- X #define null_width 32
- X #define null_height 32
- X--- 15,21 ----
- X
- X static int cur_grid = -1;
- X extern int CANVAS_WIDTH, CANVAS_HEIGHT;
- X! extern appresStruct appres;
- X
- X #define null_width 32
- X #define null_height 32
- X***************
- X*** 98,104 ****
- X grid_args[0].value = (XtArgVal)null_pm;
- X grid = -1;
- X }
- X! if( INCHES )
- X {
- X if (grid == F_GRID1)
- X grid_args[0].value = (XtArgVal)quarter_pm;
- X--- 98,104 ----
- X grid_args[0].value = (XtArgVal)null_pm;
- X grid = -1;
- X }
- X! if( appres.INCHES )
- X {
- X if (grid == F_GRID1)
- X grid_args[0].value = (XtArgVal)quarter_pm;
- END_OF_FILE
- if test 793 -ne `wc -c <'grid.c.diff'`; then
- echo shar: \"'grid.c.diff'\" unpacked with wrong size!
- fi
- # end of 'grid.c.diff'
- fi
- if test -f 'move.c.diff' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'move.c.diff'\"
- else
- echo shar: Extracting \"'move.c.diff'\" \(1182 characters\)
- sed "s/^X//" >'move.c.diff' <<'END_OF_FILE'
- X*** move.c.p5 Tue Jan 16 17:21:07 1990
- X--- move.c Sat Mar 17 13:34:46 1990
- X***************
- X*** 110,118 ****
- X erase_pointmarker();
- X set_temp_cursor(&null_cursor);
- X win_setmouseposition(canvas_swfd, px, py);
- X- pw_batch_on(canvas_pixwin);
- X draw_ellipse(e, background_color);
- X- pw_batch_off(canvas_pixwin);
- X init_ellipsedragging(e, px, py);
- X set_temp_cursor(&null_cursor);
- X clean_up();
- X--- 110,116 ----
- X***************
- X*** 123,131 ****
- X set_temp_cursor(&wait_cursor);
- X erase_pointmarker();
- X win_setmouseposition(canvas_swfd, px, py);
- X- pw_batch_on(canvas_pixwin);
- X draw_arc(a, background_color);
- X- pw_batch_off(canvas_pixwin);
- X init_arcdragging(a, px, py);
- X set_temp_cursor(&null_cursor);
- X clean_up();
- X--- 121,127 ----
- X***************
- X*** 136,144 ****
- X set_temp_cursor(&wait_cursor);
- X win_setmouseposition(canvas_swfd, px, py);
- X erase_pointmarker();
- X- pw_batch_on(canvas_pixwin);
- X draw_spline(s, ERASE);
- X- pw_batch_off(canvas_pixwin);
- X init_splinedragging(s, px, py);
- X set_temp_cursor(&null_cursor);
- X clean_up();
- X--- 132,138 ----
- END_OF_FILE
- if test 1182 -ne `wc -c <'move.c.diff'`; then
- echo shar: \"'move.c.diff'\" unpacked with wrong size!
- fi
- # end of 'move.c.diff'
- fi
- if test -f 'msgsw.c.diff' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'msgsw.c.diff'\"
- else
- echo shar: Extracting \"'msgsw.c.diff'\" \(3184 characters\)
- sed "s/^X//" >'msgsw.c.diff' <<'END_OF_FILE'
- X*** msgsw.c.p5 Wed Mar 7 10:01:07 1990
- X--- msgsw.c Tue Mar 20 17:33:47 1990
- X***************
- X*** 64,88 ****
- X
- X static Arg msg_args[] =
- X {
- X! /* 0 */ { XtNx, (XtArgVal)0 },
- X! /* 1 */ { XtNy, (XtArgVal)0 },
- X! /* 2 */ { XtNwidth, (XtArgVal)0 },
- X! /* 3 */ { XtNheight, (XtArgVal)MSG_HEIGHT },
- X! /* 4 */ { XtNlabel, (XtArgVal)"" },
- X! /* 5 */ { XtNfromHoriz, (XtArgVal)NULL },
- X! /* 6 */ { XtNhorizDistance, (XtArgVal) 2 },
- X! /* 7 */ { XtNfromVert, (XtArgVal)NULL },
- X! /* 8 */ { XtNvertDistance, (XtArgVal) 1 },
- X! /* 9 */ { XtNleft, (XtArgVal) XtChainLeft },
- X! /*10 */ { XtNinput, (XtArgVal) TRUE }, /* doesn't seem to work for DECwindows */
- X };
- X
- X int init_msg(tool)
- X TOOL tool;
- X {
- X! msg_args[2].value = PANEL_WID+CANVAS_WIDTH+SIDERULER_WIDTH-FONT_PANE_WIDTH;
- X! msg_args[5].value = (XtArgVal)psfont; /* to the right of font ind. */
- X! msg_args[7].value = (XtArgVal)canvas_sw; /* just below the canvas */
- X msg_sw = XtCreateManagedWidget("message", commandWidgetClass, tool,
- X msg_args, XtNumber(msg_args));
- X return (1);
- X--- 64,88 ----
- X
- X static Arg msg_args[] =
- X {
- X! /* 0 */ { XtNwidth, (XtArgVal) 0 },
- X! /* 1 */ { XtNheight, (XtArgVal)MSG_HEIGHT },
- X! /* 2 */ { XtNlabel, (XtArgVal)"" },
- X! /* 3 */ { XtNfromHoriz, (XtArgVal)NULL },
- X! /* 4 */ { XtNhorizDistance, (XtArgVal) 2 },
- X! /* 5 */ { XtNfromVert, (XtArgVal)NULL },
- X! /* 6 */ { XtNvertDistance, (XtArgVal) -1 },
- X! /* 7 */ { XtNleft, (XtArgVal) XtChainLeft },
- X! /* 8 */ { XtNinput, (XtArgVal) True },
- X };
- X
- X int init_msg(tool)
- X TOOL tool;
- X {
- X! /* width */
- X! msg_args[0].value = PANEL_WID+CANVAS_WIDTH+SIDERULER_WIDTH -
- X! FONT_PANE_WIDTH;
- X! msg_args[3].value = (XtArgVal)psfont; /* to the right of font ind. */
- X! msg_args[5].value = (XtArgVal)canvas_sw; /* just below the canvas */
- X msg_sw = XtCreateManagedWidget("message", commandWidgetClass, tool,
- X msg_args, XtNumber(msg_args));
- X return (1);
- X***************
- X*** 114,121 ****
- X int arg1, arg2, arg3, arg4, arg5;
- X {
- X sprintf(prompt, format, arg1, arg2, arg3, arg4, arg5);
- X! msg_args[4].value = (XtArgVal)prompt;
- X! XtSetValues(msg_sw, &msg_args[4], 1);
- X }
- X
- X /* floating point version - MIPS (DEC3100) doesn't like ints where floats are used */
- X--- 114,121 ----
- X int arg1, arg2, arg3, arg4, arg5;
- X {
- X sprintf(prompt, format, arg1, arg2, arg3, arg4, arg5);
- X! msg_args[2].value = (XtArgVal)prompt;
- X! XtSetValues(msg_sw, &msg_args[2], 1);
- X }
- X
- X /* floating point version - MIPS (DEC3100) doesn't like ints where floats are used */
- X***************
- X*** 126,139 ****
- X float arg1, arg2, arg3, arg4, arg5;
- X {
- X sprintf(prompt, format, arg1, arg2, arg3, arg4, arg5);
- X! msg_args[4].value = (XtArgVal)prompt;
- X! XtSetValues(msg_sw, &msg_args[4], 1);
- X }
- X
- X clear_message()
- X {
- X! msg_args[4].value = (XtArgVal)"";
- X! XtSetValues(msg_sw, &msg_args[4], 1);
- X }
- X
- X static
- X--- 126,139 ----
- X float arg1, arg2, arg3, arg4, arg5;
- X {
- X sprintf(prompt, format, arg1, arg2, arg3, arg4, arg5);
- X! msg_args[2].value = (XtArgVal)prompt;
- X! XtSetValues(msg_sw, &msg_args[2], 1);
- X }
- X
- X clear_message()
- X {
- X! msg_args[2].value = (XtArgVal)"";
- X! XtSetValues(msg_sw, &msg_args[2], 1);
- X }
- X
- X static
- END_OF_FILE
- if test 3184 -ne `wc -c <'msgsw.c.diff'`; then
- echo shar: \"'msgsw.c.diff'\" unpacked with wrong size!
- fi
- # end of 'msgsw.c.diff'
- fi
- if test -f 'patchlevel.h.diff' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'patchlevel.h.diff'\"
- else
- echo shar: Extracting \"'patchlevel.h.diff'\" \(171 characters\)
- sed "s/^X//" >'patchlevel.h.diff' <<'END_OF_FILE'
- X*** patchlevel.h.p5 Thu Mar 1 13:18:06 1990
- X--- patchlevel.h Tue Mar 13 17:06:14 1990
- X***************
- X*** 1 ****
- X! #define PATCHLEVEL 4
- X--- 1 ----
- X! #define PATCHLEVEL 5
- END_OF_FILE
- if test 171 -ne `wc -c <'patchlevel.h.diff'`; then
- echo shar: \"'patchlevel.h.diff'\" unpacked with wrong size!
- fi
- # end of 'patchlevel.h.diff'
- fi
- if test -f 'popup.c.diff' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'popup.c.diff'\"
- else
- echo shar: Extracting \"'popup.c.diff'\" \(3248 characters\)
- sed "s/^X//" >'popup.c.diff' <<'END_OF_FILE'
- X*** popup.c.p5 Fri Mar 9 13:50:30 1990
- X--- popup.c Wed Mar 21 11:47:27 1990
- X***************
- X*** 59,70 ****
- X static char quit_msg[] = "CONFIRM with LEFT button, CANCEL with RIGHT or MIDDLE button";
- X static char edit_msg[] = "Figures are modified; please CONFIRM with LEFT button or CANCEL with RIGHT button";
- X
- X static Arg menu_args[] =
- X {
- X! { XtNx, (XtArgVal)0 },
- X! { XtNy, (XtArgVal)0 },
- X! { XtNwidth, (XtArgVal)0 },
- X! { XtNheight, (XtArgVal)0 },
- X };
- X
- X extern void pane_select();
- X--- 59,69 ----
- X static char quit_msg[] = "CONFIRM with LEFT button, CANCEL with RIGHT or MIDDLE button";
- X static char edit_msg[] = "Figures are modified; please CONFIRM with LEFT button or CANCEL with RIGHT button";
- X
- X+ /* currently, no arguments are needed for the menu widget */
- X+
- X static Arg menu_args[] =
- X {
- X! { XtNwidth, (XtArgVal)0 },
- X };
- X
- X extern void pane_select();
- X***************
- X*** 77,87 ****
- X
- X static Arg pane_args[] =
- X {
- X- { XtNx, (XtArgVal)10 },
- X- { XtNy, (XtArgVal)30 },
- X { XtNlabel, (XtArgVal)" " },
- X { XtNwidth, (XtArgVal)0 },
- X- { XtNheight, (XtArgVal)0 },
- X { XtNcallback, (XtArgVal)pane_callbacks },
- X };
- X
- X--- 76,83 ----
- X***************
- X*** 119,131 ****
- X rlen = tlen;
- X }
- X
- X! pane_args[2].value = (XtArgVal)"COMMANDS";
- X title = XtCreateManagedWidget("title", labelWidgetClass,
- X! panes, pane_args, 4);
- X
- X /* create the first pane */
- X mi = &pumenu_items[0];
- X! pane_args[2].value = (XtArgVal)mi->label;
- X pane_callbacks[0].closure = (caddr_t)mi;
- X pane = XtCreateManagedWidget("pane", commandWidgetClass,
- X panes, pane_args, XtNumber(pane_args));
- X--- 115,127 ----
- X rlen = tlen;
- X }
- X
- X! pane_args[0].value = (XtArgVal)"COMMANDS";
- X title = XtCreateManagedWidget("title", labelWidgetClass,
- X! panes, pane_args, XtNumber(pane_args));
- X
- X /* create the first pane */
- X mi = &pumenu_items[0];
- X! pane_args[0].value = (XtArgVal)mi->label;
- X pane_callbacks[0].closure = (caddr_t)mi;
- X pane = XtCreateManagedWidget("pane", commandWidgetClass,
- X panes, pane_args, XtNumber(pane_args));
- X***************
- X*** 137,150 ****
- X XtGetValues(pane, &my_list, 1);
- X
- X /* set the width of this pane and the title to the correct width */
- X! pane_args[3].value = char_width(temp_font) * rlen + 10;
- X! XtSetValues(title, &pane_args[3], 1);
- X! XtSetValues(pane, &pane_args[3], 1);
- X
- X for (i = 1; i < XtNumber(pumenu_items); ++i)
- X {
- X mi = &pumenu_items[i];
- X! pane_args[2].value = (XtArgVal)mi->label;
- X pane_callbacks[0].closure = (caddr_t)mi;
- X pane = XtCreateManagedWidget("pane", commandWidgetClass,
- X panes, pane_args, XtNumber(pane_args));
- X--- 133,146 ----
- X XtGetValues(pane, &my_list, 1);
- X
- X /* set the width of this pane and the title to the correct width */
- X! pane_args[1].value = char_width(temp_font) * rlen + 10;
- X! XtSetValues(title, &pane_args[1], 1);
- X! XtSetValues(pane, &pane_args[1], 1);
- X
- X for (i = 1; i < XtNumber(pumenu_items); ++i)
- X {
- X mi = &pumenu_items[i];
- X! pane_args[0].value = (XtArgVal)mi->label;
- X pane_callbacks[0].closure = (caddr_t)mi;
- X pane = XtCreateManagedWidget("pane", commandWidgetClass,
- X panes, pane_args, XtNumber(pane_args));
- END_OF_FILE
- if test 3248 -ne `wc -c <'popup.c.diff'`; then
- echo shar: \"'popup.c.diff'\" unpacked with wrong size!
- fi
- # end of 'popup.c.diff'
- fi
- if test -f 'read1_3.c.diff' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'read1_3.c.diff'\"
- else
- echo shar: Extracting \"'read1_3.c.diff'\" \(329 characters\)
- sed "s/^X//" >'read1_3.c.diff' <<'END_OF_FILE'
- X*** read1_3.c.p5 Thu Mar 1 19:48:50 1990
- X--- read1_3.c Thu Mar 22 15:11:10 1990
- X***************
- X*** 30,36 ****
- X #define DRAW_COMPOUND 13
- X
- X extern F_arrow *forward_arrow(), *backward_arrow();
- X- extern int figure_modified;
- X extern int errno;
- X extern char *sys_errlist[];
- X extern int sys_nerr, errno;
- X--- 30,35 ----
- END_OF_FILE
- if test 329 -ne `wc -c <'read1_3.c.diff'`; then
- echo shar: \"'read1_3.c.diff'\" unpacked with wrong size!
- fi
- # end of 'read1_3.c.diff'
- fi
- if test -f 'redisplay.c.diff' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'redisplay.c.diff'\"
- else
- echo shar: Extracting \"'redisplay.c.diff'\" \(331 characters\)
- sed "s/^X//" >'redisplay.c.diff' <<'END_OF_FILE'
- X*** redisplay.c.p5 Tue Jan 16 17:21:08 1990
- X--- redisplay.c Sat Mar 17 13:35:00 1990
- X***************
- X*** 123,131 ****
- X
- X clear_canvas();
- X set_temp_cursor(&wait_cursor);
- X- pw_batch_on(canvas_pixwin);
- X redisplay_objects(&objects);
- X redisplay_grid();
- X- pw_batch_off(canvas_pixwin);
- X reset_cursor();
- X }
- X--- 123,129 ----
- END_OF_FILE
- if test 331 -ne `wc -c <'redisplay.c.diff'`; then
- echo shar: \"'redisplay.c.diff'\" unpacked with wrong size!
- fi
- # end of 'redisplay.c.diff'
- fi
- if test -f 'remove.c.diff' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'remove.c.diff'\"
- else
- echo shar: Extracting \"'remove.c.diff'\" \(1220 characters\)
- sed "s/^X//" >'remove.c.diff' <<'END_OF_FILE'
- X*** remove.c.p5 Tue Jan 16 17:21:08 1990
- X--- remove.c Sat Mar 17 13:35:17 1990
- X***************
- X*** 84,92 ****
- X }
- X else if ((e = ellipse_search(x, y, TOLERANCE, &dummy, &dummy)) != NULL){
- X toggle_ellipsepointmarker(e);
- X- pw_batch_on(canvas_pixwin);
- X draw_ellipse(e, background_color);
- X- pw_batch_off(canvas_pixwin);
- X delete_ellipse(&objects.ellipses, e);
- X clean_up();
- X set_action_object(F_REMOVE, O_ELLIPSE);
- X--- 84,90 ----
- X***************
- X*** 95,103 ****
- X }
- X else if ((a = arc_search(x, y, TOLERANCE, &dummy, &dummy)) != NULL){
- X toggle_arcpointmarker(a);
- X- pw_batch_on(canvas_pixwin);
- X draw_arc(a, background_color);
- X- pw_batch_off(canvas_pixwin);
- X delete_arc(&objects.arcs, a);
- X clean_up();
- X set_action_object(F_REMOVE, O_ARC);
- X--- 93,99 ----
- X***************
- X*** 106,114 ****
- X }
- X else if ((s = spline_search(x, y, TOLERANCE, &dummy, &dummy)) != NULL) {
- X toggle_splinepointmarker(s);
- X- pw_batch_on(canvas_pixwin);
- X draw_spline(s, ERASE);
- X- pw_batch_off(canvas_pixwin);
- X delete_spline(&objects.splines, s);
- X clean_up();
- X set_action_object(F_REMOVE, O_SPLINE);
- X--- 102,108 ----
- END_OF_FILE
- if test 1220 -ne `wc -c <'remove.c.diff'`; then
- echo shar: \"'remove.c.diff'\" unpacked with wrong size!
- fi
- # end of 'remove.c.diff'
- fi
- if test -f 'resources.h.diff' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'resources.h.diff'\"
- else
- echo shar: Extracting \"'resources.h.diff'\" \(1622 characters\)
- sed "s/^X//" >'resources.h.diff' <<'END_OF_FILE'
- X*** resources.h.p5 Mon Mar 12 11:18:31 1990
- X--- resources.h Fri Mar 16 15:50:25 1990
- X***************
- X*** 40,45 ****
- X--- 40,60 ----
- X NULL /* object data pointer for extension */ \
- X }
- X
- X+ /* resources structure */
- X+
- X+ typedef struct _appres {
- X+ Boolean INCHES;
- X+ Boolean DEBUG;
- X+ Boolean RHS_PANEL;
- X+ Boolean INVERSE;
- X+ Boolean TRACKING;
- X+ Boolean landscape;
- X+ char *normalFont;
- X+ char *boldFont;
- X+ float tmp_width;
- X+ float tmp_height;
- X+ } appresStruct, *appresPtr;
- X+
- X typedef struct
- X {
- X int x, y;
- X***************
- X*** 96,102 ****
- X typedef MenuRec MENU;
- X
- X #define set_marker(win,x,y,w,h,op,pix,z1,z2) \
- X! set_line_width(1,(op)); \
- X XDrawRectangle(tool_d,(win),gccache[(op)],(x),(y),(w),(h))
- X
- X EXTERN PIXWIN canvas_pixwin,
- X--- 111,117 ----
- X typedef MenuRec MENU;
- X
- X #define set_marker(win,x,y,w,h,op,pix,z1,z2) \
- X! set_line_stuff(1,SOLID_LINE,0.0,(op)); \
- X XDrawRectangle(tool_d,(win),gccache[(op)],(x),(y),(w),(h))
- X
- X EXTERN PIXWIN canvas_pixwin,
- X***************
- X*** 149,155 ****
- X #define NUMFILLPATS 5
- X #endif
- X
- X! EXTERN int cur_gcfont[0x10],cur_gcfontsize[0x10]; /* font/size currently in each GC */
- X EXTERN GC gc, bold_gc, gccache[0x10], topgc, sidegc,
- X fill_gc[NUMFILLPATS], /* area fill gc's */
- X un_fill_gc[NUMFILLPATS]; /* area "un"-fill gc's */
- X--- 164,170 ----
- X #define NUMFILLPATS 5
- X #endif
- X
- X! EXTERN int gc_font[0x10],gc_fontsize[0x10]; /* font/size currently in each GC */
- X EXTERN GC gc, bold_gc, gccache[0x10], topgc, sidegc,
- X fill_gc[NUMFILLPATS], /* area fill gc's */
- X un_fill_gc[NUMFILLPATS]; /* area "un"-fill gc's */
- END_OF_FILE
- if test 1622 -ne `wc -c <'resources.h.diff'`; then
- echo shar: \"'resources.h.diff'\" unpacked with wrong size!
- fi
- # end of 'resources.h.diff'
- fi
- if test -f 'troff_fonts.c.diff' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'troff_fonts.c.diff'\"
- else
- echo shar: Extracting \"'troff_fonts.c.diff'\" \(1794 characters\)
- sed "s/^X//" >'troff_fonts.c.diff' <<'END_OF_FILE'
- X*** /dev/null Tue Mar 27 16:38:25 1990
- X--- troff_fonts.c Tue Mar 27 16:05:00 1990
- X***************
- X*** 0 ****
- X--- 1,75 ----
- X+ /*
- X+ ** troff_fonts.c
- X+ **
- X+ ** read a table of troff font code definitions related to laserwriter
- X+ ** font names as used in psfonts.c
- X+ */
- X+
- X+ #define FONTFILE "troff_ft_codes"
- X+ #define FONTLIBDIR "/usr/lib/X11/troff"
- X+
- X+ #include <stdio.h>
- X+ #include "troff_fonts.h"
- X+
- X+ troff_init()
- X+ {
- X+ FILE *fp,
- X+ *fopen();
- X+ char fname[128],
- X+ line[128],
- X+ *p,
- X+ *strchr(),
- X+ *strcpy(),
- X+ *strncpy(),
- X+ *strcat(),
- X+ *malloc();
- X+ int linecount = 0,
- X+ fontcount = 0;
- X+
- X+ if(!font_file)
- X+ font_file = FONTFILE;
- X+ if((fp = fopen(font_file, "r")) == NULL)
- X+ {
- X+ (void) sprintf(fname, "%s/%s", FONTLIBDIR, font_file);
- X+ if((fp = fopen(fname, "r")) == NULL)
- X+ {
- X+ fprintf(stderr,"f2p: cannot open %s\n", fname);
- X+ exit(1);
- X+ }
- X+ }
- X+ while(fgets(line, sizeof line, fp) != NULL)
- X+ {
- X+ linecount++;
- X+ if(line[0] == '#' || line[0] == '\n')
- X+ continue;
- X+ if(fontcount + 1 == MAX_TROFF_FONTS)
- X+ {
- X+ fprintf(stderr,"f2p: too many fonts in %s\n",fname);
- X+ exit(1);
- X+ }
- X+ if((p = strchr(line, '\t')) == NULL)
- X+ {
- X+ fprintf(stderr,"f2p: %s lacks tab char in line %d\n",
- X+ fname, linecount);
- X+ exit(1);
- X+ }
- X+ *p = '\0';
- X+ if(strlen(line) > 2)
- X+ {
- X+ fprintf(stderr,
- X+ "f2p: code \"%s\" too long in %s line %d\n",
- X+ line, fname, linecount);
- X+ exit(1);
- X+ }
- X+ (void) strcpy(troff_fonts[fontcount].trname,line);
- X+ if((troff_fonts[fontcount].lwname=malloc((unsigned)strlen(++p)))
- X+ == NULL)
- X+ {
- X+ fprintf(stderr,"f2p: malloc failed\n");
- X+ exit(1);
- X+ }
- X+ (void) strncpy(troff_fonts[fontcount++].lwname,p,strlen(p)-1);
- X+ /* not '\n' */
- X+ }
- X+ (void) fclose(fp);
- X+ }
- END_OF_FILE
- if test 1794 -ne `wc -c <'troff_fonts.c.diff'`; then
- echo shar: \"'troff_fonts.c.diff'\" unpacked with wrong size!
- fi
- # end of 'troff_fonts.c.diff'
- fi
- if test -f 'troff_fonts.h.diff' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'troff_fonts.h.diff'\"
- else
- echo shar: Extracting \"'troff_fonts.h.diff'\" \(276 characters\)
- sed "s/^X//" >'troff_fonts.h.diff' <<'END_OF_FILE'
- X*** /dev/null Tue Mar 27 16:38:25 1990
- X--- troff_fonts.h Tue Mar 27 16:09:06 1990
- X***************
- X*** 0 ****
- X--- 1,10 ----
- X+ #define MAX_TROFF_FONTS 50
- X+
- X+ char *font_file;
- X+
- X+ struct lw_troff_map
- X+ {
- X+ char trname[3];
- X+ char *lwname;
- X+ } troff_fonts[MAX_TROFF_FONTS];
- X+
- END_OF_FILE
- if test 276 -ne `wc -c <'troff_fonts.h.diff'`; then
- echo shar: \"'troff_fonts.h.diff'\" unpacked with wrong size!
- fi
- # end of 'troff_fonts.h.diff'
- fi
- if test -f 'troff_ft_codes.diff' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'troff_ft_codes.diff'\"
- else
- echo shar: Extracting \"'troff_ft_codes.diff'\" \(1067 characters\)
- sed "s/^X//" >'troff_ft_codes.diff' <<'END_OF_FILE'
- X*** /dev/null Tue Mar 27 16:38:25 1990
- X--- troff_ft_codes Tue Mar 27 16:35:31 1990
- X***************
- X*** 0 ****
- X--- 1,40 ----
- X+ # map of laserwriter font names to troff 2 letter codes
- X+ # for use by f2p, the xfig to pic translator
- X+ # normal path: /usr/lib/X11/troff/troff_ft_codes
- X+
- X+ R Times-Roman
- X+ I Times-Italic
- X+ B Times-Bold
- X+ BI Times-BoldItalic
- X+ AR AvantGarde
- X+ AO AvantGarde-BookOblique
- X+ AB AvantGarde-Demi
- X+ AX AvantGarde-DemiOblique
- X+ K Bookman-Light
- X+ KO Bookman-LightItalic
- X+ KB Bookman-Demi
- X+ KX Bookman-DemiItalic
- X+ C Courier
- X+ CO Courier-Oblique
- X+ CB Courier-Bold
- X+ CX Courier-BoldItalic
- X+ H Helvetica
- X+ HO Helvetica-Oblique
- X+ HB Helvetica-Bold
- X+ HX Helvetica-BoldOblique
- X+ h Helvetica-Narrow
- X+ hO Helvetica-Narrow-Oblique
- X+ hB Helvetica-Narrow-Bold
- X+ hX Helvetica-Narrow-BoldOblique
- X+ NR NewCenturySchlbk-Roman
- X+ NI NewCenturySchlbk-Italic
- X+ NB NewCenturySchlbk-Bold
- X+ NX NewCenturySchlbk-BoldItalic
- X+ PR Palatino-Roman
- X+ PI Palatino-Italic
- X+ PB Palatino-Bold
- X+ PX Palatino-BoldItalic
- X+ S Symbol
- X+ ZC ZapfChancery-MediumItalic
- X+ ZD ZapfDingbats
- X+
- END_OF_FILE
- if test 1067 -ne `wc -c <'troff_ft_codes.diff'`; then
- echo shar: \"'troff_ft_codes.diff'\" unpacked with wrong size!
- fi
- # end of 'troff_ft_codes.diff'
- fi
- echo shar: End of archive 1 \(of 7\).
- cp /dev/null ark1isdone
- MISSING=""
- for I in 1 2 3 4 5 6 7 ; do
- if test ! -f ark${I}isdone ; then
- MISSING="${MISSING} ${I}"
- fi
- done
- if test "${MISSING}" = "" ; then
- echo You have unpacked all 7 archives.
- rm -f ark[1-9]isdone
- else
- echo You still need to unpack the following archives:
- echo " " ${MISSING}
- fi
- ## End of shell archive.
- exit 0
-
- dan
- -----------------------------------------------------------
- O'Reilly && Associates
- argv@sun.com / argv@ora.com
- 632 Petaluma Ave, Sebastopol, CA 95472
- 800-338-NUTS, in CA: 800-533-NUTS, FAX 707-829-0104
- Opinions expressed reflect those of the author only.
-